﻿@model MsForgeReboot.Web.Models.LocalPasswordProfileModel
@{
    ViewBag.Title = "Manage Account";
}

<hgroup class="title">
    <h1>@ViewBag.Title.</h1>
</hgroup>

<p class="message-success">@ViewBag.StatusMessage</p>

<p>You're logged in as <strong>@User.Identity.Name</strong>.</p>
@using (Html.BeginForm("Manage", "Account")) {
    @Html.AntiForgeryToken()
    @Html.ValidationSummary()
        <div class="editor-label">
            @Html.LabelFor(model => model.UserName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.UserName)
            @Html.ValidationMessageFor(model => model.UserName)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.PublicName)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.PublicName)
            @Html.ValidationMessageFor(model => model.PublicName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Notifications)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Notifications)
            @Html.ValidationMessageFor(model => model.Notifications)
        </div>


if (ViewBag.HasLocalPassword)
{
    <fieldset>
        <legend>Change Password Form</legend>
                @Html.LabelFor(m => m.OldPassword)
                @Html.PasswordFor(m => m.OldPassword)
                @Html.LabelFor(m => m.NewPassword)
                @Html.PasswordFor(m => m.NewPassword)
                @Html.LabelFor(m => m.ConfirmPassword)
                @Html.PasswordFor(m => m.ConfirmPassword)
    </fieldset>
}
else
{ 
    @Html.Partial("_SetPasswordPartial")
}
        <p>
            <button class="btn btn-success">Izmeni! <i class="icon-save"></i></button>
        </p>
}
<section id="externalLogins">
    @Html.Action("RemoveExternalLogins")

    <h3>Add an external login</h3>
    @Html.Action("ExternalLoginsList", new { ReturnUrl = ViewBag.ReturnUrl })
</section>

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
